package com.raja.servingStation.common.util;

/**
 * 错误码构成为前三位为系统号，后四位为错误码编号
 * Created by tianjie on 2017/3/10.
 */
public enum ErrorCode {
    ERR_PARAM("10000001","参数输入错误,不能为空"),
    ERR_SQL_EXECUTE("10000002","数据库语句执行异常"),
    ERR_GET_WX_ACCESS_TOKEN("10000003","获取微信access_token失败"),
    ERR_GET_WX_OPENID("10000004","获取微信open_id失败"),
    ERR_GET_WX_USERINFO("10000005","获取认证信息信息失败"),
    ERR_CANNOT_GET_USER_INFO("10000006","获取不到用户登录session信息"),
    ERR_FALUT_REASON_NULL("10000007","请填写故障信息"),
    ERR_REPAIR_RESULT_NULL("10000008","请填写维修记录"),
    ERR_VERIFICATION("10000009","验证码填写不正确"),
    ERR_VERIFICATION_CANNOT_BE_NULL("10000010","验证码不能为空"),
    ERR_MOBILE_FORMAT("10000011","手机号格式错误"),
    ERR_SMS_SEND_FAILED("10000012","验证码发送失败，可能是服务器正忙，请稍后再试"),
    ERR_DATETIME_FORMAT("10000013","错误的时间格式"),
    ERR_ORDER_HAS_BEEN_EVALUATION("10000014","该工单不能评价"),
    ERR_GET_IMG_FROM_WX("10000015","从微信服务器获取图片失败"),
    ERR_UPLOAD_IMAGE("10000016","上传文件失败"),
    ERR_SAVE_IMG_ON_DISK("10000017","图片保存本地失败"),
    ERR_MOBILE_HAS_BEEN_BINDED("10000018","手机号和当前手机号相同，请更换手机号"),
    ERR_CAR_NOT_FOUND("10000019","车辆不存在"),
    ERR_NUMBER("10000020","输入参数不为数字"),
    ERR_PLATE_NUMBER("10000021","车牌号格式不正确"),
    ERR_CAR_ADD_ERROR("10000022","车辆添加失败"),
    ERR_CAR_EXISTS("10000023","车辆已经存在"),
    ERR_SYMTOM_TOO_LONG("10000024","故障现象描述过长"),
    ERR_CARVIN("10000026","请输入正确的车架号"),
    ERR_INNNER("10000025","系统内部错误"),
    ERR_GET_USERINFO_FROM_WX("10000026","从微信获取用户信息失败"),
    MOBILE_HAS_EXIST("10000027","手机号已经绑定其他账号."),
    CREATE_BUTTON_FAILD("10000028","创建菜单失败"),
    CHARGE_QR_FAILED("10000029","二维码验证不通过,请联系客服人员"),
    CHARGE_PILE_RUN_FAULT("10000030","当前桩状态故障，请更换充电位"),
    CHARGE_PILE_OFFLINE("10000031","该充电桩目前处于脱机状态，可以正常充电，但无法告知充电进度"),
    CHARGE_PILE_IN_USER("10000032","该充电桩目前正处于使用状态，请更换充电位"),
    MUST_CHOOSE_ONE_FAULTINFOR("10000033","必须选择或填写故障现象"),
    MUST_FAULT_COMPONENT_ID_AND_FAULT_TYPE_ID("10000034","请填写完整的零件和故障"),
    ERR_CAR_TYPE("10000035","车辆类型格式错误"),
    ERR_LOCALTION_PATTERN("10000036","所属部位参数错误"),
    ERR_ORDER_ID_CANNOT_BE_NULL("10000037","工单号不能为空"),
    ERR_PRICE_PATTERN("10000038","价格必须为数字类型"),
    ERR_DATE_PATTERN("10000039","时间不能为空"),
    ERR_DATA_PATTERN("10000040","数字精度不对"),
    ORDER_IS_NOT_EXIT("10000041","订单不存在"),
    VIST_COUNT_TOO_MANAY("10000042","访问次数太频繁"),
    ;


    private String errorCode;

    private String errorMsg;

    ErrorCode(String errorCode, String errorMsg) {
        this.errorCode = errorCode;
        this.errorMsg = errorMsg;
    }

    public String getErrorCode() {
        return errorCode;
    }

//    public void setErrorCode(String errorCode) {
//        this.errorCode = errorCode;
//    }

    public String getErrorMsg() {
        return errorMsg;
    }

//    public void setErrorMsg(String errorMsg) {
//        this.errorMsg = errorMsg;
//    }
}
